#!/bin/bash

#conda activate image-compress

# crf: 15 17 19 21 23 25 27 29 31 33 35 37 39 41 43 45 47 49 51
for num in $(seq 17 2 52)
do
  for snr in $(seq 1 1 5)   # snr: 1 2 3 4 5
  do
    echo "crf: ${num}, snr: ${snr}>>"
    # CLIC dataset
    python /workspace/cx-data/chenxin/h265_ldpc/x265_image_ldpc_qam_channel.py \
    --input_folder /workspace/cx-data/25-06月/实验记录/x265/图像/CLIC/mkv/${num} \
    --output_folder /workspace/cx-data/25-06月/实验记录/x265/图像/CLIC/ldpc_qam_awgn_snr${snr}/${num} \
    --snr ${snr} --ldpc_rate 0.5 --qam_m 16 --ldpc_design_file ./channel_codec/1440.720.txt \
    --channel_type awgn --suffix .mkv

    # Kodak dataset
    python /workspace/cx-data/chenxin/h265_ldpc/x265_image_ldpc_qam_channel.py \
    --input_folder /workspace/cx-data/25-06月/实验记录/x265/图像/Kodak/mkv/${num} \
    --output_folder /workspace/cx-data/25-06月/实验记录/x265/图像/Kodak/ldpc_qam_awgn_snr${snr}/${num} \
    --snr ${snr} --ldpc_rate 0.5 --qam_m 16 --ldpc_design_file ./channel_codec/1440.720.txt \
    --channel_type awgn --suffix .mkv

    # Tecnick dataset
    python /workspace/cx-data/chenxin/h265_ldpc/x265_image_ldpc_qam_channel.py \
    --input_folder /workspace/cx-data/25-06月/实验记录/x265/图像/Tecnick/mkv/${num} \
    --output_folder /workspace/cx-data/25-06月/实验记录/x265/图像/Tecnick/ldpc_qam_awgn_snr${snr}/${num} \
    --snr ${snr} --ldpc_rate 0.5 --qam_m 16 --ldpc_design_file ./channel_codec/1440.720.txt \
    --channel_type awgn --suffix .mkv
  done
done

